From: Jonas Dreßler Date: Wed, 22 Apr 2020 19:14:13 +0000 (+0200) Subject: unlockDialog: Call AuthPrompt.addCharacter() directly X-Git-Tag: archive/raspbian/50.5-1+rpi1~1^2~684^2^2~468 X-Git-Url: https://dgit.raspbian.org/%22http://www.example.com/cgi/%22/%22http:/www.example.com/cgi/%22?a=commitdiff_plain;h=fb1bb291eb5be666fcefd63ec68d33d45d0a6a1b;p=gnome-shell.git unlockDialog: Call AuthPrompt.addCharacter() directly The additional function UnlockDialog.addCharacter() is only used at one place, so we can simply remove it and call AuthPrompt.addCharacter() directly. The AuthPrompt is shown right before that anyway. https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1209 --- diff --git a/js/ui/unlockDialog.js b/js/ui/unlockDialog.js index 2170f12a7..29122ca51 100644 --- a/js/ui/unlockDialog.js +++ b/js/ui/unlockDialog.js @@ -605,7 +605,7 @@ var UnlockDialog = GObject.registerClass({ this._showPrompt(); if (GLib.unichar_isgraph(unichar)) - this.addCharacter(unichar); + this._authPrompt.addCharacter(unichar); return Clutter.EVENT_PROPAGATE; } @@ -835,11 +835,6 @@ var UnlockDialog = GObject.registerClass({ this._authPrompt.cancel(); } - addCharacter(unichar) { - this._showPrompt(); - this._authPrompt.addCharacter(unichar); - } - finish(onComplete) { this._ensureAuthPrompt(); this._authPrompt.finish(onComplete);